﻿using System.Data;
using System;
using System.Runtime.Serialization;
using System.ServiceModel;

namespace HRMService
{
    // NOTE: If you change the interface name "IEditInsBook" here, you must also update the reference to "IEditInsBook" in App.config.
    [ServiceContract(Namespace = "http://HRMService")]
    public interface IEditInsBook
    {
        //[OperationContract]
        //int EditInsBook_Using(int EditInsBookID);

        [OperationContract]
        DataSet EditInsBook_GetAll();

        [OperationContract]
        EditInsBookInfo EditInsBook_GetInfo(int EditInsBookID);

        [OperationContract]
        DataSet EditInsBook_GetList(out int ItemCount, int _month, int _year, int branchID, int departmentID,int currentPage, int pageSize);

        [OperationContract]
        int EditInsBook_Insert(EditInsBookInfo eInfo);

        [OperationContract]
        bool EditInsBook_Update(EditInsBookInfo eInfo);

        [OperationContract]
        bool EditInsBook_Delete(int EditInsBookID);
        [OperationContract]
        DataSet EditInsBook_Report(int BranchID, int _month, int _year);
    }

    [DataContract(Namespace = "http://HRMService")]
    public class EditInsBookInfo
    {
        int _ID;
        [DataMember]
        public int ID
        {
            get { return _ID; }
            set { _ID = value; }
        }
        int _EmployeeID;
        [DataMember]
        public int EmployeeID
        {
            get { return _EmployeeID; }
            set { _EmployeeID = value; }
        }
        string _Content;
        [DataMember]
        public string Content
        {
            get { return _Content; }
            set { _Content = value; }
        }
        string _Old;
        [DataMember]
        public string Old
        {
            get { return _Old; }
            set { _Old = value; }
        }
        string _New;
        [DataMember]
        public string New
        {
            get { return _New; }
            set { _New = value; }
        }
        string _Cause;
        [DataMember]
        public string Cause
        {
            get { return _Cause; }
            set { _Cause = value; }
        }
        DateTime _EditDate;
        [DataMember]
        public DateTime EditDate
        {
            get { return _EditDate; }
            set { _EditDate = value; }
        }
    }
}
